﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MyMaster.master" AutoEventWireup="true" CodeFile="TinTucChiTiet.aspx.cs" Inherits="TinTucChiTiet" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
        <asp:SqlDataSource ID="sql_TinTuc" runat="server" 
                            ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
                            SelectCommand="SELECT * FROM tintuc WHERE id_row = @id_row">
            <SelectParameters>
                <asp:QueryStringParameter Name="id_row" QueryStringField="id_row" Type="String" />
            </SelectParameters>
        </asp:SqlDataSource>
        <asp:DataList ID="datalistTinTuc" runat="server"  DataKeyField="id_row" 
            DataSourceID="sql_TinTuc">
            <ItemTemplate>
                <table style="margin:10px; text-align:center">
                    <tr>
                        <td>
                            <asp:Label runat="server" ID="lbTieuDe" Text='<%# Eval("TIEUDE") %>' Font-Size="20">
                            </asp:Label>
                            <br /><br />
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Image ID="imgHinhAnh" runat="server" Height="200px"
                                ImageUrl='<%# "~/images/TinTuc/" + Eval("id_row") + "/hinhchude.jpg" %>' />
                        </td>
                    </tr>
                    <tr>
                        <td style="vertical-align:middle; text-align:justify">
                            <asp:Label runat="server" ID="lbNoiDung" Text='<%# Eval("NOIDUNG") %>'>
                            </asp:Label>
                        </td>
                    </tr>
                </table>
            </ItemTemplate>
        </asp:DataList>    
</asp:Content>

